<template>
  <div>
    <div style="border-radius: 4px">
      <h1 style="font-size: 30px ;margin:0px 350px 20px 450px">DHRLS</h1>
      <el-form ref="form" :model="form" label-width="80px" style="margin: 0px 350px">
        <el-form-item label="OMIM ID">
          <el-input v-model="form.name" placeholder="Input Disease ID" style="width: 220px"></el-input>
        </el-form-item>
        <el-form-item label="Method">
          <el-select v-model="form.method" placeholder="Select method" >
            <el-option label="DHRLS_Pathway(default)" value="default"></el-option>
<!--            <el-option label="NIDM_M_Vmt" value="Vmt"></el-option>-->
          </el-select>
        </el-form-item>
        <el-form-item label="Top index">
          <el-input style="width: 220px" v-model="form.top" placeholder="input top index"></el-input>
        </el-form-item>
        <el-form-item>
          <el-button type="primary" @click="onSubmit">Submit</el-button>
        </el-form-item>
      </el-form>
      <img src="@/assets/DHRLS.png" style="margin: 0px 110px">
    </div>
  </div>
</template>

<script>
import router from "@/router";
export default {
  name: 'HomeView',
  data() {
    return {
      form: {
        name: '',
        method: 'default',
        top: 10
      }
    }
  },
  methods: {
    onSubmit() {
      this.$router.push({
        path: '/result',
        query: {
          name: this.form.name,
          top: this.form.top
        }
      });
    }
  }
}
</script>
